home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / gnustuff / tos / gnulib / libsrc98.zoo / clock.c < prev    next >
Encoding:
C/C++ Source or Header  |  1990-02-27  |  288 b   |  15 lines

  1. /* clock -- return process time used so far, in units of CLK_TCK ticks
  2.    per second (under TOS, 200 per second) */
  3. /* written by ERS */
  4.  
  5. #include <time.h>
  6. #include <sysvars.h>
  7.  
  8. clock_t _start_time;
  9.  
  10. clock_t
  11. clock(void)
  12. {
  13.     return ((clock_t) get_sysvar((void *) _hz_200) - _start_time);
  14. }
  15.